package gao.xiaolei.entity;

import lombok.Data;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;

@Data
@Entity
@Table(name = "classes_group_user_view")
public class ClassesGroupUserView {
    @Id// 添加一个空的id标识，因为jpa在映射实体是需要一个id，这个必须

    @Column(name = "classes_id")
    private String classesId;

    @Column(name = "classes_name")
    private String classesName;

    @Column(name = "classes_creater")
    private String classesCreater;

    @Column(name = "classes_leader")
    private String classesLeader;

    @Column(name = "group_id")
    private String groupId;

    @Column(name = "group_name")
    private String groupName;

    @Column(name = "user_id")
    private String userId;

    @Column(name = "username")
    private String username;

    @Column(name = "user_real_name")
    private String userRealName;

    public ClassesGroupUserView(String userId) {
        this.userId = userId;
    }

    public ClassesGroupUserView(String classesId, String userId) {
        this.classesId = classesId;
        this.userId = userId;
    }

    public ClassesGroupUserView() {
    }
}
